﻿<%@ Page Title="SicoNide Shipping" Language="C#" MasterPageFile="~/TableMaster.master" AutoEventWireup="true" CodeFile="SicoNide_Shipping.aspx.cs" Inherits="Pages_SicoNide_Shipping" %>

<asp:Content ID="Content1" ContentPlaceHolderID="head" runat="Server">

    <style>
        @media only screen and (max-width: 760px), (min-device-width: 768px) and (max-device-width: 1024px) {

            .resTbl tr:nth-of-type(odd) {
                background-color: #CDE2FF;
            }

            .resTbl tr:nth-of-type(1) {
                display: none;
            }

            .resTbl td:nth-of-type(1):before {
                content: "Drum_# ";
            }

            .resTbl td:nth-of-type(2):before {
                content: "Net Weight to Be shipped ";
            }

            .resTbl td:nth-of-type(3):before {
                content: "Gross Weight to Be shipped ";
            }

            .resTbl td:nth-of-type(4):before {
                content: "Shipping Date ";
            }

            .resTbl td:nth-of-type(5):before {
                content: "PO Number ";
            }

            .resTbl td:nth-of-type(6):before {
                content: "Shipping Method ";
            }

            .resTbl td:nth-of-type(7):before {
                content: "Shipping Vessel ";
            }

            .resTbl td:nth-of-type(8):before {
                content: "Created By";
            }

            .resTbl td:nth-of-type(9):before {
                content: "Created Date";
            }
        }
    </style>

</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="FeaturedContent" runat="Server">
</asp:Content>
<asp:Content ID="Content3" ContentPlaceHolderID="Add" runat="Server">



    <asp:Panel ID="pnlAdd" runat="server">

        <table cellpadding="0" cellspacing="0" style="width: 100%;">

            <tr>
                <td style="width: 200px">
                    <asp:Label ID="lblDrum_Number" runat="server" AssociatedControlID="ddlDrum_Number" Text="Drum # :"></asp:Label>
                </td>
                <td>
                    <asp:DropDownList ID="ddlDrum_Number" runat="server">
                        <asp:ListItem Value="0">--Select--</asp:ListItem>
                        <asp:ListItem>D001</asp:ListItem>
                    </asp:DropDownList>
                </td>
            </tr>

            <tr>
                <td style="width: 200px">
                    <asp:Label ID="lblNet_Weight_Shipped" runat="server" AssociatedControlID="txtNet_Weight_Shipped" Text="Net Weight to Be shipped :"></asp:Label>
                </td>
                <td>
                    <asp:TextBox ID="txtNet_Weight_Shipped" runat="server"></asp:TextBox>
                </td>
            </tr>

            <tr>
                <td style="width: 200px">
                    <asp:Label ID="lblGross_Weight_Shipped" runat="server" AssociatedControlID="txtGross_Weight_Shipped" Text="Gross Weight to Be shipped :"></asp:Label>
                </td>
                <td>
                    <asp:TextBox ID="txtGross_Weight_Shipped" runat="server"></asp:TextBox>
                </td>
            </tr>

            <tr>
                <td style="width: 200px">
                    <asp:Label ID="lblShipping_Date" runat="server" AssociatedControlID="txtShipping_Date" Text="Shipping Date :"></asp:Label>
                </td>
                <td>
                    <asp:TextBox ID="txtShipping_Date" runat="server" type="date"></asp:TextBox>
                </td>
            </tr>

            <tr>
                <td style="width: 200px">
                    <asp:Label ID="lblPO_Number" runat="server" AssociatedControlID="ddlPO_Number" Text="PO Number :"></asp:Label>
                </td>
                <td>
                    <asp:DropDownList ID="ddlPO_Number" runat="server" DataSourceID="DS_PO_Num" DataTextField="PURCHASE_ORDER_NO" DataValueField="PO_ID" OnDataBound="ddlPO_Number_DataBound"></asp:DropDownList>
                    <asp:ObjectDataSource ID="DS_PO_Num" runat="server" SelectMethod="selectAll" TypeName="DAL_tbl_purchase_order"></asp:ObjectDataSource>
                </td>
            </tr>

            <tr>
                <td style="width: 200px">
                    <asp:Label ID="lblShipping_Method" runat="server" AssociatedControlID="ddlShipping_Method" Text="Shipping Method :"></asp:Label>
                </td>
                <td>
                    <asp:DropDownList ID="ddlShipping_Method" runat="server">
                    </asp:DropDownList>
                </td>
            </tr>

            <tr>
                <td style="width: 200px">
                    <asp:Label ID="lblShipping_Vessel" runat="server" AssociatedControlID="txtShipping_Vessel" Text="Shipping Vessel :"></asp:Label>
                </td>
                <td>
                    <asp:TextBox ID="txtShipping_Vessel" runat="server"></asp:TextBox>
                </td>
            </tr>




            <tr>
                <td style="width: 200px">&nbsp;</td>
                <td>

                    <asp:Button ID="btnSave" runat="server" CssClass="btn btn-success" OnClick="btnSave_Click" Text="Save" Width="90px" />
                    &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
                    <asp:Button ID="btnCancel" runat="server" CssClass="btn btn-danger" OnClick="btnCancel_Click" Text="Cancel" Width="90px" />

                </td>
            </tr>

        </table>

    </asp:Panel>



</asp:Content>
<asp:Content ID="Content4" ContentPlaceHolderID="Grid" runat="Server">
    <asp:Panel ID="pnlList" runat="server">
        <asp:GridView ID="gridClients" runat="server" AutoGenerateColumns="False" CssClass="resTbl" DataSourceID="DS_tbl_siconide_shipping">
            <Columns>
                <asp:BoundField DataField="Drum_Number" HeaderText="Drum # " SortExpression="Drum_Number" />
                <asp:BoundField DataField="Net_Weight_Shipped" HeaderText="Net Weight to Be shipped " SortExpression="Net_Weight_Shipped" />
                <asp:BoundField DataField="Gross_Weight_Shipped" HeaderText="Gross Weight to Be shipped " SortExpression="Gross_Weight_Shipped" />
                <asp:BoundField DataField="Shipping_Date" HeaderText="Shipping Date " SortExpression="Shipping_Date" DataFormatString="{0:yyMMdd}" />
                <asp:BoundField DataField="PO_Number" HeaderText="PO Number " SortExpression="PO_Number" />
                <asp:BoundField DataField="Shipping_Method" HeaderText="Shipping Method " SortExpression="Shipping_Method" />
                <asp:BoundField DataField="Shipping_Vessel" HeaderText="Shipping Vessel " SortExpression="Shipping_Vessel" />
                <asp:BoundField DataField="CREATED_BY" HeaderText="Created By" SortExpression="CREATED_BY" />
                <asp:BoundField DataField="CREATED_DATE" HeaderText="Created Date" SortExpression="CREATED_DATE" DataFormatString="{0:yyMMdd}" />

                <asp:TemplateField HeaderText="Edit">
                    <ItemTemplate>
                        <asp:LinkButton ID="linkEdit" runat="server" Text="Edit" CommandArgument='<%# Eval("ID") %>' OnClick="linkEdit_Click"></asp:LinkButton>
                    </ItemTemplate>
                </asp:TemplateField>
                <asp:TemplateField HeaderText="Delete">
                    <ItemTemplate>
                        <asp:LinkButton ID="linkDelete" CommandName="delete" runat="server" Text="Delete" OnClientClick="javascript:return confirm('Are you sure you want to delete this record?');" CommandArgument='<%# Eval("ID") %>' OnClick="linkDelete_Click"></asp:LinkButton>
                    </ItemTemplate>
                </asp:TemplateField>
            </Columns>
        </asp:GridView>
        <asp:ObjectDataSource ID="DS_tbl_siconide_shipping" runat="server" SelectMethod="selectAllForGrid" DeleteMethod="delete" InsertMethod="insert" UpdateMethod="update" TypeName="DAL_tbl_siconide_shipping">
            <DeleteParameters>
                <asp:Parameter Name="ID" Type="Int32" />
            </DeleteParameters>
            <InsertParameters>
                <asp:Parameter Name="Drum_Number" Type="String" />
                <asp:Parameter Name="Net_Weight_Shipped" Type="Decimal" />
                <asp:Parameter Name="Gross_Weight_Shipped" Type="Decimal" />
                <asp:Parameter Name="Shipping_Date" Type="DateTime" />
                <asp:Parameter Name="PO_Number" Type="String" />
                <asp:Parameter Name="Shipping_Method" Type="String" />
                <asp:Parameter Name="Shipping_Vessel" Type="String" />
                <asp:Parameter Name="CREATED_BY" Type="String" />
                <asp:Parameter Name="CREATED_DATE" Type="DateTime" />
            </InsertParameters>
            <UpdateParameters>
                <asp:Parameter Name="Drum_Number" Type="String" />
                <asp:Parameter Name="Net_Weight_Shipped" Type="Decimal" />
                <asp:Parameter Name="Gross_Weight_Shipped" Type="Decimal" />
                <asp:Parameter Name="Shipping_Date" Type="DateTime" />
                <asp:Parameter Name="PO_Number" Type="String" />
                <asp:Parameter Name="Shipping_Method" Type="String" />
                <asp:Parameter Name="Shipping_Vessel" Type="String" />
                <asp:Parameter Name="UPDATED_BY" Type="String" />
                <asp:Parameter Name="UPDATED_DATE" Type="DateTime" />
            </UpdateParameters>
        </asp:ObjectDataSource>
    </asp:Panel>
</asp:Content>
